package com.czzhan.captcha.web;

import com.czzhan.captcha.common.annotation.WebInterceptCaptcha;
import org.springframework.web.bind.annotation.GetMapping;
import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.web.bind.annotation.RestController;

/**
 * TestController
 *
 * @author czzhan
 * @date 2024/5/5 15:04
 */
@RestController
@RequestMapping("/test")
public class TestController {

    @GetMapping(value = "/captcha")
    @WebInterceptCaptcha(ipTriggerLimit = 1, ipUpperLimit = 10)
    public Object captcha() {
        return "接口正常返回";
    }

    @GetMapping(value = "/noCaptcha")
    public String noCaptcha() {
        return "12345";
    }

}
